package VN.EDU.IMIC.DEVELOPER.DOTHANHTUNG.OOP_MVC_LV1.makeFriend;

public class makeFriendModel {
	public boolean checkInfo(People objHuman){
		switch (objHuman.getGioiTinh()) {
		case "nam":
			if (objHuman.getTuoi()>=22 && objHuman.getTinhTrang().equals("docthan")|| objHuman.getTinhTrang().equals("lyhon")){
				return true;
			}
			else {
				return false;
			}
		case "nu":
			if (objHuman.getTuoi()>=19 && objHuman.getTinhTrang().equals("docthan")|| objHuman.getTinhTrang().equals("lyhon")){
				return true;
			}
			else {
				return false;
			}
		}
		return false;	
	}

}
